<template>
  <div class="base-root">
    <div class="loop-box">
      <div v-for="(item, index) in goodsClsList" :key="index" class="item">
        <div class="info-box">
          <span class="icon iconfont el-icon-ex-biaoqian lable-cls"></span>
          <span class="txt-cls">{{item.cate_name}}</span>
        </div>
      </div>
    </div>
    <div class="link-box" @click="goUrl">查看全部商品</div>
  </div>
</template>


<script>
  export default {
    name: "LableList",
    props: {
      goodsClsList: {
        type: Array,
        default: () => ([])
      },
      linkUrl: {
        type: String,
        default: ''
      }
    },
    computed: {

    },
    methods: {
      goUrl() {
        window.location.href = this.linkUrl;
      }

    }
  };
</script>

<style>
  .item {
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 30px;
    background-color: #eee;
    color: #333;
    padding: 2px 15px;
    box-sizing: border-box;
    align-content: center;

  }

  .info-box {
    display: flex;
    align-items: center;



  }

  .txt-cls{
    padding-left:4px;
    padding-top: 2px;
  }

  .lable-cls {
    padding-top: 2px;
    color: #4876FF;
    font-size: 14px;
  }

  .link-box {
    margin-top: 10px;
    color: #4876FF;
    font-size: 14px;
    display: flex;
    cursor: pointer;

  }

  .loop-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
</style>
